package entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.dot.base.json.JsonUtils;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.Date;

/**
 * @author : xuzhennan
 * @Project : 787k-cloud
 * @Package : PACKAGE_NAME
 * @email : xuzhennan@58.com
 * @date : 2021年08月29日 上午8:57
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class Article implements Serializable {
    @TableId(value = "id",type = IdType.AUTO)
    private Integer id;
    private String title;
    private String blogImg;
    private String content;
    private String htmlContent;
    private Integer readed;
    private Integer authorId;
    private String authorName;
    private Integer cateId;
    private Date created;
    private Date updated;

    @Override
    public String toString() {
        return JsonUtils.toJson(this);
    }
}
